package com.github.pig.admin.model.zhgl.unit;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;

/**
 * <p>
 * 楼宇单元基本信息表
 * </p>
 *
 * @author lxm
 * @since 2018-06-12
 */
@TableName("building_unit")
public class BuildingUnit extends Model<BuildingUnit> {

    private static final long serialVersionUID = 1L;

    public static String BUILDING_TYPE_HOUSE="0";//住宅
    public static String BUILDING_TYPE_COMMERCIAL="1";//商用

    /**
     * 唯一标识
     */
    @TableId(value = "id",type = IdType.UUID)
    private String id;
    /**
     * 楼宇标识
     */
    @TableField("building_id")
    private String buildingId;

    @TableField(exist = false)
    private String buildingName;
    /**
     * 单元名称
     */
    @TableField("unit_name")
    private String unitName;
    /**
     * 保洁
     */
    @TableField("cleaning_user")
    private String cleaningUser;
    /**
     * 安全负责人
     */
    @TableField("safe_user")
    private String safeUser;
    /**
     * 删除标识-1：已删除 0：正常
     */
    @TableField("del_flag")
    private String delFlag;

    /**
     * 序号
     */
    @TableField("sort")
    private int sort;

    @TableField("community_id")
    private String communityId;

    public String getCommunityId() {
        return communityId;
    }

    public void setCommunityId(String communityId) {
        this.communityId = communityId;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getBuildingId() {
        return buildingId;
    }

    public void setBuildingId(String buildingId) {
        this.buildingId = buildingId;
    }

    public String getUnitName() {
        return unitName;
    }

    public void setUnitName(String unitName) {
        this.unitName = unitName;
    }

    public String getCleaningUser() {
        return cleaningUser;
    }

    public void setCleaningUser(String cleaningUser) {
        this.cleaningUser = cleaningUser;
    }

    public String getSafeUser() {
        return safeUser;
    }

    public void setSafeUser(String safeUser) {
        this.safeUser = safeUser;
    }

    public String getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    public String getBuildingName() {
        return buildingName;
    }

    public void setBuildingName(String buildingName) {
        this.buildingName = buildingName;
    }

    public int getSort() {
        return sort;
    }

    public void setSort(int sort) {
        this.sort = sort;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "BuildingUnit{" +
        ", id=" + id +
        ", buildingId=" + buildingId +
        ", unitName=" + unitName +
        ", cleaningUser=" + cleaningUser +
        ", safeUser=" + safeUser +
        ", delFlag=" + delFlag +
        "}";
    }
}
